package com.es.www.aopContext;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.EnableAspectJAutoProxy;

import com.es.www.aopContext.service.UserService;

/**
 * @Created by michangtao
 * @Date 2022/2/8 14:57
 * @Description
 */
@EnableAspectJAutoProxy(exposeProxy = true)
@ComponentScan("com.es.www.aopContext")
public class UserAspectApplication {

    public static void main(String[] args) {
        AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(UserAspectApplication.class);
        UserService userService = ctx.getBean(UserService.class);
        userService.update("1","mct");
    }
}
